import req from "../utils/req.js"
import {req_Get_Index_Data} from "./constant.js"

export default{
	namespaced:true,
	state:{
			// 首页数据
			indexData:{}
	},
	mutations:{
		[req_Get_Index_Data]:(state,data)=>{
			state.indexData = data
		}
	},
	actions:{
		// 请求首页数据
		async reqGetIndexData({commit},value){
			const data = await req(value)
			commit(req_Get_Index_Data,data)
		}
	},
	getters:{
		
	}
}